package chapetr04.Example24_31;

public class Example24 {
    public static void main(String[] args) {
        int result = divide(4,0);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        int result = x/y;
        return result;
    }

}
 +17 Example25.java  0 -> 100644
package chapetr04.Example24_31;

public class Example25 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
    }catch (Exception e){
        System.out.println("捕获的异常信息为："+e.getMessage());
    }
        System.out.println("程序继续向下执行...");
}
public static int divide(int x, int y) {
    int result = x / y;
    return result;
}
}
 +21 Example26.java  0 -> 100644
package chapetr04.Example24_31;

public class Example26 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            System.out.println("捕获的异常信息为："+e.getMessage());
            return;
    }finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
        }
        public static int divide(int x, int y) {
        int result = x / y;
        return result;

        }
}
 +22 Example27.java  0 -> 100644
package chapetr04.Example24_31;

public class Example27 {
    public static void main(String[] args) {
        try {
            int result = divide(4, 0);
            System.out.println(result);
        } catch (Exception e) {
            System.out.println();
            return;
        } finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
    }

    public static int divide(int x, int y) throws Exception {
        int result = x / y;
        return result;
    }
}
 +16 Example28.java  0 -> 100644
package chapetr04.Example24_31;

public class Example28 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            e.printStackTrace();
        }
}
public static int divide(int x, int y) throws Exception{
    int result = x / y;
    return result;
}
}
 +12 Example29.java  0 -> 100644
package chapetr04.Example24_31;

public class Example29 {
    public static void main(String[] args)throws Exception {
        int result = divide(4, 0);
        System.out.println(result);
    }
    public static int divide(int x, int y)throws Exception {
        int result = x/y;
        return result;
    }
}
 +16 Example30.java  0 -> 100644
package chapetr04.Example24_31;

public class Example30 {
    public static void main(String[] args) {
        int result=divide(4,-2);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        if (y<0){
 //           throw new DivideByMinusException("turt");
        }

            int result = x /y;
            return result;
        }
    }
 +19 Example31.java  0 -> 100644
package chapetr04.Example24_31;

public class Example31 {
    public static void main(String[] args) {
        try {
            int result = divide(4, -2);
            System.out.println(result);
        } catch (DivideByMinusException e) {
            System.out.println(e.getMessage());
        }
    }
    public static int divide(int x, int y ) throws DivideByMinusException {
        if (y<0){
            throw new DivideByMinusException("除数是负数");
        }
        int result = x / y;
        return result;
    }
  }

package chapetr04.Example24_31;

public class Example24 {
    public static void main(String[] args) {
        int result = divide(4,0);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        int result = x/y;
        return result;
    }

}
 +17 Example25.java  0 -> 100644
package chapetr04.Example24_31;

public class Example25 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
    }catch (Exception e){
        System.out.println("捕获的异常信息为："+e.getMessage());
    }
        System.out.println("程序继续向下执行...");
}
public static int divide(int x, int y) {
    int result = x / y;
    return result;
}
}
 +21 Example26.java  0 -> 100644
package chapetr04.Example24_31;

public class Example26 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            System.out.println("捕获的异常信息为："+e.getMessage());
            return;
    }finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
        }
        public static int divide(int x, int y) {
        int result = x / y;
        return result;

        }
}
 +22 Example27.java  0 -> 100644
package chapetr04.Example24_31;

public class Example27 {
    public static void main(String[] args) {
        try {
            int result = divide(4, 0);
            System.out.println(result);
        } catch (Exception e) {
            System.out.println();
            return;
        } finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
    }

    public static int divide(int x, int y) throws Exception {
        int result = x / y;
        return result;
    }
}
 +16 Example28.java  0 -> 100644
package chapetr04.Example24_31;

public class Example28 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            e.printStackTrace();
        }
}
public static int divide(int x, int y) throws Exception{
    int result = x / y;
    return result;
}
}
 +12 Example29.java  0 -> 100644
package chapetr04.Example24_31;

public class Example29 {
    public static void main(String[] args)throws Exception {
        int result = divide(4, 0);
        System.out.println(result);
    }
    public static int divide(int x, int y)throws Exception {
        int result = x/y;
        return result;
    }
}
 +16 Example30.java  0 -> 100644
package chapetr04.Example24_31;

public class Example30 {
    public static void main(String[] args) {
        int result=divide(4,-2);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        if (y<0){
 //           throw new DivideByMinusException("turt");
        }

            int result = x /y;
            return result;
        }
    }
 +19 Example31.java  0 -> 100644
package chapetr04.Example24_31;

public class Example31 {
    public static void main(String[] args) {
        try {
            int result = divide(4, -2);
            System.out.println(result);
        } catch (DivideByMinusException e) {
            System.out.println(e.getMessage());
        }
    }
    public static int divide(int x, int y ) throws DivideByMinusException {
        if (y<0){
            throw new DivideByMinusException("除数是负数");
        }
        int result = x / y;
        return result;
    }
  }
package chapetr04.Example24_31;

public class Example24 {
    public static void main(String[] args) {
        int result = divide(4,0);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        int result = x/y;
        return result;
    }

}
 +17 Example25.java  0 -> 100644
package chapetr04.Example24_31;

public class Example25 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
    }catch (Exception e){
        System.out.println("捕获的异常信息为："+e.getMessage());
    }
        System.out.println("程序继续向下执行...");
}
public static int divide(int x, int y) {
    int result = x / y;
    return result;
}
}
 +21 Example26.java  0 -> 100644
package chapetr04.Example24_31;

public class Example26 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            System.out.println("捕获的异常信息为："+e.getMessage());
            return;
    }finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
        }
        public static int divide(int x, int y) {
        int result = x / y;
        return result;

        }
}
 +22 Example27.java  0 -> 100644
package chapetr04.Example24_31;

public class Example27 {
    public static void main(String[] args) {
        try {
            int result = divide(4, 0);
            System.out.println(result);
        } catch (Exception e) {
            System.out.println();
            return;
        } finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
    }

    public static int divide(int x, int y) throws Exception {
        int result = x / y;
        return result;
    }
}
 +16 Example28.java  0 -> 100644
package chapetr04.Example24_31;

public class Example28 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            e.printStackTrace();
        }
}
public static int divide(int x, int y) throws Exception{
    int result = x / y;
    return result;
}
}
 +12 Example29.java  0 -> 100644
package chapetr04.Example24_31;

public class Example29 {
    public static void main(String[] args)throws Exception {
        int result = divide(4, 0);
        System.out.println(result);
    }
    public static int divide(int x, int y)throws Exception {
        int result = x/y;
        return result;
    }
}
 +16 Example30.java  0 -> 100644
package chapetr04.Example24_31;

public class Example30 {
    public static void main(String[] args) {
        int result=divide(4,-2);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        if (y<0){
 //           throw new DivideByMinusException("turt");
        }

            int result = x /y;
            return result;
        }
    }
 +19 Example31.java  0 -> 100644
package chapetr04.Example24_31;

public class Example31 {
    public static void main(String[] args) {
        try {
            int result = divide(4, -2);
            System.out.println(result);
        } catch (DivideByMinusException e) {
            System.out.println(e.getMessage());
        }
    }
    public static int divide(int x, int y ) throws DivideByMinusException {
        if (y<0){
            throw new DivideByMinusException("除数是负数");
        }
        int result = x / y;
        return result;
    }
  }
package chapetr04.Example24_31;

public class Example24 {
    public static void main(String[] args) {
        int result = divide(4,0);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        int result = x/y;
        return result;
    }

}
 +17 Example25.java  0 -> 100644
package chapetr04.Example24_31;

public class Example25 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
    }catch (Exception e){
        System.out.println("捕获的异常信息为："+e.getMessage());
    }
        System.out.println("程序继续向下执行...");
}
public static int divide(int x, int y) {
    int result = x / y;
    return result;
}
}
 +21 Example26.java  0 -> 100644
package chapetr04.Example24_31;

public class Example26 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            System.out.println("捕获的异常信息为："+e.getMessage());
            return;
    }finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
        }
        public static int divide(int x, int y) {
        int result = x / y;
        return result;

        }
}
 +22 Example27.java  0 -> 100644
package chapetr04.Example24_31;

public class Example27 {
    public static void main(String[] args) {
        try {
            int result = divide(4, 0);
            System.out.println(result);
        } catch (Exception e) {
            System.out.println();
            return;
        } finally {
            System.out.println("进入finally代码块");
        }
        System.out.println("程序继续向下执行...");
    }

    public static int divide(int x, int y) throws Exception {
        int result = x / y;
        return result;
    }
}
 +16 Example28.java  0 -> 100644
package chapetr04.Example24_31;

public class Example28 {
    public static void main(String[] args) {
        try{
            int result = divide(4,0);
            System.out.println(result);
        }catch (Exception e){
            e.printStackTrace();
        }
}
public static int divide(int x, int y) throws Exception{
    int result = x / y;
    return result;
}
}
 +12 Example29.java  0 -> 100644
package chapetr04.Example24_31;

public class Example29 {
    public static void main(String[] args)throws Exception {
        int result = divide(4, 0);
        System.out.println(result);
    }
    public static int divide(int x, int y)throws Exception {
        int result = x/y;
        return result;
    }
}
 +16 Example30.java  0 -> 100644
package chapetr04.Example24_31;

public class Example30 {
    public static void main(String[] args) {
        int result=divide(4,-2);
        System.out.println(result);
    }
    public static int divide(int x, int y) {
        if (y<0){
 //           throw new DivideByMinusException("turt");
        }

            int result = x /y;
            return result;
        }
    }
 +19 Example31.java  0 -> 100644
package chapetr04.Example24_31;

public class Example31 {
    public static void main(String[] args) {
        try {
            int result = divide(4, -2);
            System.out.println(result);
        } catch (DivideByMinusException e) {
            System.out.println(e.getMessage());
        }
    }
    public static int divide(int x, int y ) throws DivideByMinusException {
        if (y<0){
            throw new DivideByMinusException("除数是负数");
        }
        int result = x / y;
        return result;
    }
  }


